home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The CDPD Public Domain Collection for CDTV 4
/
CDPD_IV.bin
/
e
/
mailinglists
/
amigae.0793july.archive
/
000025_crash!minyos.xx….OZ.AU!s924723_Mon, 12 Jul 93 19:45:30 PST.msg
< prev
next >
Wrap
Internet Message Format
|
1994-05-26
|
3KB
Received: by bkhouse.cts.com (V1.16/Amiga)
id AA00000; Mon, 12 Jul 93 19:45:30 PST
Received: from peladon.rmit.OZ.AU by crash.cts.com with smtp
(Smail3.1.28.1 #15) id m0oFZKh-0000SmC; Mon, 12 Jul 93 18:39 PDT
Received: from minyos.xx.rmit.OZ.AU by peladon.rmit.OZ.AU with SMTP id AA24687
(5.65c/IDA-1.4.4 for <amigae@bkhouse.cts.com>); Tue, 13 Jul 1993 11:38:50 +1000
Received: by minyos.xx.rmit.OZ.AU
Message-Id: <9307130139.25470@minyos.xx.rmit.OZ.AU>
Date: Tue, 13 Jul 1993 11:39:03 +1000 (EST)
In-Reply-To: <9307121546.6733@minyos.xx.rmit.OZ.AU> from "Barry D. Wills" at Jul 12, 93 10:43:00 am
X-Mailer: ELM [version 2.4 PL22]
Mime-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Content-Length: 2569
From: s924723@minyos.xx.rmit.OZ.AU (Son Huu Le)
To: amigae@bkhouse.cts.com
Subject: Re: Optimizing E
>
> Hi, Son Le. Long time, eh?
(; Working on anything lately, Barry?
> >what are the proper arguments for the DOS function SetVBuf()? The DOS
> >manual says it accepts 4 arguments, E only accepts 3!?
>
> I remember you asking this before. Don't know, so I didn't answer.
I was hoping Wouter could answer this for me. He properly missed the last one.
> >I was debugging my programs, I noticed that E always(?) used MOVE.L x(A5),D0
> >for variable storage/retrieval. In a tight loop, a MOVE.L x(AN),D0
> >will cost more cycle time than a MOVE.L D1,D0. Since E doesn't touch the
> >other data registers often, it would help speed time greatly if you could
> >use them.
>
> Hmmmm. What debugger do you use?
Monam with Devpac. It's great, once you get use to it. (;
> I'm interested in the results of replacing:
> in E... x++ <-> INC x
> in C... x++ <-> x += 1
Well, in the first case, E produced the exact code, minus that bogus instr. I
queried.. hmmm.. weird. In the second case.. the same. Did Wouter say that
the new version can output debug symbols?
> I recall Wouter saying that ++ returns a value and eats up some ticks in the
> process. That may be what's going on in that Asm instruction you questioned,
> the value is being returned in D0. The C compiler sees that you're not doing
> anything with the returned value, so optimizes it away.
Sound logical. But E could be much faster if it detected a loop or a low number
of variables, and transfer them all to data registers. Or perhaps a keyword
that you can use to tell E you want the variable in a register and if there's
a free register, E uses it. A bit more work, but if you're going to produce
efficient and compact codes, it's essential.
> >One last suggestion.. how about making some E functions (such as WriteF)
> >more assembling friendly, so you can use certain E functions in the middle
> >of an assembly code? ie. it uses only the upper data/address registers (4-7)
> >and leaves the lower ones intact.
>
> Wouter told me you can do this:
> MOVEM D0-D7/A0-A3,(A7)+ ;/* Save multiple regs, post inc stack (SP). */
> WriteF ('whatever')
> MOVEM -(A7),D0-D7/A0-A3 ;/* Pre dec stack, restore multiple regs (SP). */
>
> I'm not at home right now, so I'm not sure about the syntax. A7 here is the
> program stack pointer (SP). If you want to correct the syntax and post it to
> the list, I'd appreciate it.
Good idea, forgot about it. Still, a bit cumbersome, but it's do.
Btw: The syntax looks pretty much like the correct syntax. (;
Cheers..
Son Le